import 'package:flutter/material.dart';
import 'package:sky_ui/sky_ui.dart';
import '../common/space.dart';

class AlertDemo2 extends StatefulWidget {
  const AlertDemo2({super.key});

  @override
  State<AlertDemo2> createState() => _AlertDemo2State();
}

class _AlertDemo2State extends State<AlertDemo2> {
  @override
  Widget build(BuildContext context) {
    return const Column(
      crossAxisAlignment: CrossAxisAlignment.start,
      children: [
        SkyRow(
          children: [
            SkyCol(
              span: 24,
              child: SkyAlert(
                title: "成功提示的文案",
                type: SkyAlertType.success,
                effect: SkyAlertEffect.dark,
                closable: true,
              ),
            )
          ],
        ),
        DemoSpace.vGap20,
        SkyRow(
          children: [
            SkyCol(
              span: 24,
              child: SkyAlert(
                title: "消息提示的文案",
                type: SkyAlertType.info,
                effect: SkyAlertEffect.dark,
                closable: true,
              ),
            )
          ],
        ),
        DemoSpace.vGap20,
        SkyRow(
          children: [
            SkyCol(
              span: 24,
              child: SkyAlert(
                title: "警告提示的文案",
                type: SkyAlertType.warning,
                effect: SkyAlertEffect.dark,
                closable: true,
              ),
            )
          ],
        ),
        DemoSpace.vGap20,
        SkyRow(
          children: [
            SkyCol(
              span: 24,
              child: SkyAlert(
                title: "错误提示的文案",
                type: SkyAlertType.error,
                effect: SkyAlertEffect.dark,
                closable: true,
              ),
            )
          ],
        ),
      ],
    );
  }
}
